package com.frxuexi.lib_base.room

import androidx.room.Dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query

@Dao
interface ShopDao {

    @Insert(onConflict = OnConflictStrategy.REPLACE)
    fun addLove(shopEntity: ShopEntity):Long


    @Query("select * from shop where sid=:sid")
    fun isLove(sid:Int):ShopEntity

    @Query("select * from shop")
    fun getLoves():List<ShopEntity>

    @Delete
    fun deleteLove(shopEntity: ShopEntity):Int
}